package com.yikome.purchase.entity;

import java.math.BigDecimal;

import javax.persistence.Entity;
import javax.persistence.Index;
import javax.persistence.Table;

import com.yikome.common.BaseEntity;

import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;

@Setter
@Getter
@NoArgsConstructor
@Entity
@Table(name = "p_purchase" , indexes = {@Index(columnList="purchaseCode") , @Index(columnList="storehouseId")})
public class Purchase extends BaseEntity{

	private static final long serialVersionUID = 6985543698954204900L;

	private String purchaseCode ; 
	
	private String supplierName ;
	
	private String purchaseUrl ; 
	
	private Long storehouseId ; 
	
	private BigDecimal purchasePrice;
	
	private BigDecimal purchaseFreightPrice;
	
	private String comments ; 
	
	private Integer purchasedTotalQuantity;
    
    private Integer storagedTotalQuantity;
    
    private Integer cancelTotalQuantity ; 
	
	private Integer status ; // 已创建(0) | 已派单(10) | 已完成(20) | 已取消(-10)
}
